/*
docCopyright("Steve Dekorte", 2002)
docLicense("BSD revised")
*/

#ifndef IOPYTHON_DEFINED
#define IOPYTHON_DEFINED 1

#include "IoObject.h"
#include "IoSeq.h"
#include "PythonData.h"

#define ISPYTHON(self) IoObject_hasCloneFunc_(self, (TagCloneFunc *)IoPython_rawClone)
#define DATA(self) ((PythonData *)IoObject_dataPointer(self))
#define ISIOPYTHON(self) \
  IoObject_hasCloneFunc_(self, (TagCloneFunc *)IoPython_rawClone)

typedef IoObject IoPython;

IoPython *IoPython_rawClone(IoPython *self);
IoPython *IoPython_proto(void *state);
IoPython *IoPython_new(void *state);
void IoPython_free(IoPython *self);

PyObject *convertIo(IoObject *self, IoObject *obj);
IoObject *convertPy(IoObject *self, PyObject *obj);
IoObject *forwardToParent(IoPython *self, IoObject *locals, IoMessage *m);

/* ----------------------------------------------------------- */
IoObject *IoPython_credits(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_forward(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_eval(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_import(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_invoke(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_newInstance(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_print(IoPython *self, IoObject *locals, IoMessage *m);
IoObject *IoPython_println(IoPython *self, IoObject *locals, IoMessage *m);
#endif
